/********************************************************************
	File		: AnimSprite.h
	Created		: 2011-2-21	23:05
	Author		: Wjl

	Desc		: This file is part of omiga 2d engine.
*********************************************************************/

#ifndef AnimSprite_H__
#define AnimSprite_H__

#include "Sprite.h"

namespace Vis
{
	class AnimSprite : public Sprite
	{
	public:

		AnimSprite();
		AnimSprite(const AnimSprite& _other);
		virtual ~AnimSprite();

		void	Load();
		void	Release();

		void	Display();

		void	StopAtFrame(unsigned int _frame);
		void	PlayFromFrame(unsigned int _frame = 0, bool _isLoop = true, bool _isReverse = false);
		void	NextFrame();
		void	PreFrame();
		void	Play(bool _isLoop = false, bool _isReverse = false);
		void	Stop();
	
	private:
	
		int				m_iCurFrame;
		int				m_iTotalFrames;
		bool			m_bEnable;
	};
}

#endif // AnimSprite_H__